import { http } from '@/utils/http'

/** 查询登录日志列表 */
export function listLogininfor(params?: object) {
  return http.request<HttpPaginationResponse<Array<any>>>('get', '/system/logininfor/list', {
    params,
  })
}

/** 删除登录日志 */
export function delLogininfor(infoId: number) {
  return http.request<HttpResponse<Object>>('delete', '/system/logininfor/' + infoId)
}

/** 解锁用户登录状态 */
export function unlockLogininfor(userName: string) {
  return http.request<HttpResponse<Object>>('get', '/system/logininfor/unlock/' + userName)
}

/** 清空登录日志 */
export function cleanLogininfor() {
  return http.request<HttpResponse<Object>>('delete', '/system/logininfor/clean')
}
